Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@hint/utils-fs

Package Overview
Dependencies
Maintainers
5
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hint/utils-fs

utils for filesystem

  • 1.0.16
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
12K
decreased by-22.42%
Maintainers
5
Weekly downloads
 
Created
Source

FileSystem utils (@hint/utils-fs)

Set of helpers to work with the filesystem.

Installation

This package is installed automatically when adding webhint to your project so running the following is enough:

npm install hint --save-dev

Utils

  • cwd: Returns the current working directory. Same as process.cwd().
  • fileExtension: Try to determine the resource's file extension.
  • fileName: Returns the name of a file. Same as path.basename().
  • isDirectory: Check if a path is a directory and exists.
  • isFile: Check if a path is a file and exists.
  • loadJSFile: Loads a JavaScript file.
  • loadJSONFile: Loads a JSON a file.
  • pathExists: Check if a path exists.
  • readFileAsync: Convenience wrapper for asynchronously reading file contents.
  • readFile: Convenience wrapper for synchronously reading file contents.
  • writeFileAsync: Convenience wrapper for asynchronously write a file.

Keywords

FAQs

Package last updated on 09 Jun 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc